package cd.cdyb.sms.dto.query;

import cd.cdyb.sms.dto.MessageRecordingDto;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

import javax.validation.constraints.NotNull;
import java.time.LocalDate;
import java.time.LocalDateTime;

/**
 * @Author: lilin
 * @CreateTime: 2024-05-17  17:12
 * @Description: 发送记录
 */
@Data
public class MessageRecordingQueryDto extends MessageRecordingDto {


    /**
     * 页码
     */
    private int pageNo = 1;

    /**
     * 每页大小
     */
    private int pageSize = 10;

    @JsonFormat(pattern = "yyyy-MM-dd")
    @NotNull(message = "开始时间不能为空")
    private LocalDate startDate;

    @JsonFormat(pattern = "yyyy-MM-dd")
    @NotNull(message = "截止时间不能为空")
    private LocalDate endDate;

    private String startDateWithTime;

    private String endDateWithTime;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime startTime;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private LocalDateTime endTime;
}
